<h1>Listing stories</h1>

<table>
  <tr>
    <th>Title</th>
    <th>As a</th>
    <th>I want</th>
    <th>So that</th>
    <th>State</th>
    <th>Acceptance criteria</th>
    <th>Created by</th>
    <th>Claimed by</th>
  </tr>

<% @stories.each do |story| %>
  <tr>
    <td><%=h story.title %></td>
    <td><%=h story.as_a %></td>
    <td><%=h story.i_want %></td>
    <td><%=h story.so_that %></td>
    <td><%=h story.state %></td>
    <td><%=h story.acceptance_criteria %></td>
    <td><%=h story.created_by %></td>
    <td><%=h story.claimed_by %></td>
    <td><%= link_to 'Show', story %></td>
    <td><%= link_to 'Edit', edit_story_path(story) %></td>
    <td><%= link_to 'Destroy', story, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New story', new_story_path %>